<?php


namespace app\admin\model;


use think\Model;
use think\model\concern\SoftDelete;

class Wander extends Model
{

    use SoftDelete;
    protected $name = 'wander';

    public function wanderRecord(){
        return $this->hasMany(WanderRecord::class,'wander_id');
    }

    public function promoterAdmin(){
        return $this->belongsTo(Admin::class,'promoter_id');
    }

    public function abutmentAdmin(){
        return $this->belongsTo(Admin::class,'abutment_id');
    }

    public function superiorAdmin(){
        return $this->belongsTo(Admin::class,'superior_id');
    }
    public function abutmentGroup(){
        return $this->belongsTo(AuthGroup::class,'abutment_group_id');
    }
}